﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class Default2 : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }
    protected void Button1_Click(object sender, EventArgs e)
    {
        TextBox txt1 = new TextBox();
        Page.Form.Controls.Add(txt1);
        txt1.ID = "txt1";
        txt1.Attributes.Add("runat","server");
        //txt1.Attributes.AddAttributes();
    }
}
